package br.mobilelawyer.app.hma;

import android.app.Activity;
import android.os.Bundle;
import android.webkit.WebSettings;
import android.webkit.WebView;
import android.webkit.WebViewClient;

public class MostraSiteOficial extends Activity {

	public void onCreate(Bundle icicle) {
		super.onCreate(icicle);

		// objeto que cria o componente que chama uma pagina da web independente
		// de navegador
		final WebView web = new WebView(this);

		// propriedades do componente
		WebSettings webSettings = web.getSettings();
		webSettings.setSavePassword(false);
		webSettings.setSaveFormData(false);
		webSettings.setJavaScriptEnabled(true);
		webSettings.setSupportZoom(true);
		webSettings.setBuiltInZoomControls(true);
		webSettings.setSupportMultipleWindows(true);
		webSettings.setAllowFileAccess(true);

		// url que contem o arquivo de eula
		web.loadUrl("http://ubuntuaazip.blogspot.com");

		setContentView(web);

		web.setWebViewClient(new WebViewClient() {
			@Override
			public boolean shouldOverrideUrlLoading(WebView view, String url) {
				setContentView(web);
				setRequestedOrientation(5);
				return false;
			}
		});
	}

}
